package cn.edu.scau.cmi.dengzejun.chapter09;

public class Example9_16 {
	public static void main(String args[]) {
		CalendarBean calendarBean = new CalendarBean();
		calendarBean.setYear(2011);
		calendarBean.setMonth(7);
		String[] temp = calendarBean.getCalendar();
		char[] str = "SunMonTueWedThuFriSat".toCharArray();
		for (char ch:str) {
			System.out.printf("%3c", ch);
		}
		for (int i = 0;i<temp.length;++i) {
			if ((i%7==0)) {
				System.out.println("");
			}
			System.out.printf("%4s", temp[i]);
		}
		return;
	}
}
